<?php
/*
* Author: Nguyen Hai Nam
* Module: AboutUsModule
* Desc	: Introduce pick.vn and sidle pic
* Date	: 12/12/2011
*/
class RAndDModule extends Pick_Core_Module{
	function RAndDModule(){
		parent::Pick_Core_Module();
		# Languages
		$languages = new Pick_Core_Languages();
		$objectLanguages = "";
		$objectLanguages = $languages->getObjects(1, 'status = 1', array('position'=>'ASC'), '');
		if($objectLanguages){
			$objectLanguages = $objectLanguages['data'];	
		}#endif
		$this->template->assign("objectLanguages", $objectLanguages);
	}
	public function getContent(){

		$news = new Pick_Dao_News();
		$id = $this->request->get('id', '');
		$objNews = "";
        $backgroundimage = "";
		if($id){
			$objNews = $news->getObject($id);
            $backgroundimage = $objNews->getFullUrlBackGround();
		}
        $this->template->assign('backgroundimage', $backgroundimage);
		$this->template->assign('objNews', $objNews);
		$this->template->assign('id', $id);
		unset($news);
		unset($objNews);
		unset($id);
	}
}